package com.balabala.gym_system.controller.app;


import com.balabala.gym_system.pojo.dto.ReservationListDto;
import com.balabala.gym_system.pojo.entity.ReservationInfo;
import com.balabala.gym_system.pojo.vo.ReservationVo;
import com.balabala.gym_system.service.ReservationInfoService;
import com.balabala.gym_system.service.ReservationListService;
import com.balabala.result.Result;
import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import java.util.List;

@Slf4j
@RestController
@Api(tags = "APP用户预约信息接口")
@RequestMapping("/app/ReservationInfo")
@CrossOrigin
public class ReservationInfoAppController {

    @Autowired
    private ReservationInfoService reservationInfoService;




    /*//根据id删除预约课程表
     @GetMapping("/deleteById")
     @ApiOperation(value = "APP删除预约记录")
     public Result deleteById(@RequestParam Long id){
        reservationListService.deleteReservation(id);
        return Result.ok();
     }*/

     //用户预约团课
    @PostMapping("/addReservationInfo")
    @ApiOperation(value = "APP用户添加预约记录")
    public Result addReservationInfo(@RequestBody ReservationInfo reservationInfo){

        reservationInfoService.addReservationInfo(reservationInfo);

        return Result.ok();
    }


}
